<template>
 <div>hh</div>
</template>
<script setup lang='ts'>
import { ref, provide, toRefs, reactive } from 'vue'



let car = ref('奥迪')
let money = ref(1000000)

let video = ref()
let list = reactive([
    { width: 100, height: 100 },
    { width: 200, height: 200 },
    { width: 300, height: 300 }
])


function handleResize(index: number, event: any) {
    list[index].width = event.width
    list[index].height = event.height
}



// nextTick(() => {
//     console.log("video.value")
// })







function cutMoney() {
    money.value -= 100
}

//传给孙子
provide('car', car.value)
provide('money', { money, cutMoney })
</script>
<style scoped lang='scss'>
.container {
    border: 2px solid skyblue;
    background: gainsboro;
}
</style>
